<!DOCTYPE html>
<html lang="zh-CN">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>v-bind基本使用</title>
</head>

<body>

  <div id="app">
    <!-- 因为imgURL是动态变量 v-bind实现的功能就是可以动态绑定变量 -->
    <img v-bind:src="imgURL" alt="">

    <!-- 语法糖: ':' -->
    <a :href="myHref">百度一下</a>
  </div>

  <script src="../../js/vue.js"></script>
  <script>
    const app = new Vue({
      el: '#app',
      data: {
        message: 'hello',
        myHref: 'http://www.baidu.com',
        imgURL: "https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/c0c05274f2fbb55fbccb89622f798907.jpg?w=632&h=340"
      }
    })
  </script>
</body>

</html>